<script setup>
import LoginForm from '@/views/login/form.vue'
import {ref} from "vue";
const loginCpnRef = ref()

const submit = () => {
  loginCpnRef.value.loginAction()
}
</script>

<template>
  <div class="plan">
    <h1 class="title">easy-rbac-demo</h1>
    <a-card hoverable style="width: 300px">
      <template #cover>
        <img
            alt="example"
            src="https://gw.alipayobjects.com/zos/rmsportal/JiqGstEfoWAOHiTxclqi.png"
        />
      </template>
      <LoginForm ref="loginCpnRef"/>
    </a-card>

    <a-button style="width: 100%; margin-top: 10px" type="primary"
              @click="submit"
    >立即登录</a-button>
  </div>
</template>

<style scoped>
.title{
  text-align: center;
}
</style>